<template>
	<div>
		<el-card class="box-card">
			<div class="text item">
				<template v-for="(value, key) in propertyList">
					<div class="hoverdivClass" :key="key" v-if="titleList[key]">
						<el-form ref="form" label-position="left">
							<el-form-item :label="titleList[key]" v-if="titleList[key]">
								<el-input v-model="propertyList[key]" type="textarea"></el-input>
							</el-form-item>
						</el-form>
					</div>
				</template>
			</div>
		</el-card>
	</div>
</template>
<script>
export default {
	props: {
		getData: {
			type: Function,
			default: Function
		}
	},
	data() {
		return {
			titleList: {
				advisorEnglishName: '投资顾问英文名称',
				accountFirmName: '会计师事务所名称',

				bordersAdvisorEnglishName: '境外投资顾问英文名称',

				bordersAdvisorName: '境外投资顾问中文名称',

				bordersCustodianEnglishName: '境外托管人英文名称',

				bordersCustodianName: '境外托管人中文名称',

				custodyBranchOrganName: '托管人分支机构名称',

				fundTaTypeName: '登记机构名称',
				fundTaType: '登记机构代码',

				handleLawerName: '经办律师名称',

				investAdvisorName: '投资顾问中文名称',

				isThirdPartyCustody: '是否第三方托管',

				lawFirmName: '律师事务所名称',

				managementFullName: '管理人名称',

				trusteeFullName: '托管人名称',
				managementRegisterNumber: '管理人代码',
				trusteeRegisterNumber: '托管人代码',
				advisorRegisterNumber: '投资顾问代码',
				lawFirmRegisterNumber: '律师事务所代码',
				accountFirmRegisterNumber: '会计师事务所代码',
				investAdvisorOrgan: '投资顾问机构类型',
				investAdvisorRate: '投资顾问费率',
				iscustodyBranchOrgan: '是否有托管分支机构'
			},
			propertyList: {
				accountFirmId: '',

				bordersAdvisorEnglishName: '',

				bordersAdvisorName: '',

				bordersCustodianEnglishName: '',

				bordersCustodianName: '',

				custodyBranchOrganName: '',

				fundTaType: '',
				fundTaTypeName: '',

				handleLawerName: '',

				investAdvisorId: '',

				isThirdPartyCustody: '',

				lawId: '',

				managementId: '',

				trusteeId: '',
				managementRegisterNumber: '',
				trusteeRegisterNumber: '',
				advisorRegisterNumber: '',
				lawFirmRegisterNumber: '',
				accountFirmRegisterNumber: '',
				advisorEnglishName: '',
				investAdvisorOrgan: '',
				investAdvisorRate: '',
				iscustodyBranchOrgan: ''
			}
		}
	},
	methods: {
		saveSetings() {
			return this.propertyList
		},
		edit(data) {
			const obj = JSON.parse(JSON.stringify(data))
			this.propertyList = { ...this.propertyList, ...obj }
			for (const i in this.propertyList) {
				if (!this.propertyList[i]) {
					this.propertyList[i] = ''
				}
			}
		}
	}
}
</script>
<style lang="scss" scoped >
</style>
